The present invention relates to an ATM (Asynchronous Transfer Mode) cell sending system and, more particularly, to an ATM cell sending system in a traffic shaper for controlling the flow of cells on the basis of defined information associated with a cell traffic.
Generally, a traffic shaper is arranged in a cell sending unit for sending cells to a line, or a cell relay unit for relaying cells. The traffic shaper adjusts the cell sending interval by reserving a cell sending time in advance. A technique for determining a cell sending time is important for a traffic shaper.
As shown in FIG. 6, a conventional circuit for determining a cell sending time comprises a sending time determination circuit 11 for determining an ideal cell sending time and a cell sendable time determination circuit 12 for finding a time after the determined ideal cell sending time when a cell can be sent.
The sending time determination circuit 11 outputs, on the basis of an input cell 110, an ideal sending time 111 which is an ideal time for sending the cell to a line.
The cell sendable time determination circuit 12 comprises a selector 121 for selectively sending the ideal sending time 111 or an output from an adder 123, a sendability determination unit 122 for checking whether a sending reservation is present for a time determined by the selector 121, and the adder 123 for incrementing the time by one when a sending reservation has already been made.
In this arrangement, the ideal sending time 111 output from the sending time determination circuit 11 is input to the cell sendable time determination circuit 12. The sendability determination unit 122 checks whether a sending reservation is present for the ideal sending time 111. If no reservation is present, the sendability determination unit 122 reserves that time for cell sending.
If a reservation has already been made for the time, the sending time is incremented by one by the adder 123. The incremented time is input to the sendability determination unit 122 again through the selector 121. The sendability determination unit 122 checks whether a sending reservation is present for the incremented time. The above operation is repeated until a time having no reservation is detected.
The sending time determination circuit 11 procedure for determining the ideal sending time will be described below with reference to the flow chart in FIG. 7.
Referring to FIG. 7, an ideal sending time TOT is set equal to a cell delay fluctuation .tau.1 (step S61).
When a cell has arrived, a cell arrive time TA is set to the arrival time of the cell (step S62), and the ideal sending time TOT is compared with the cell arrival time ta (step S63). If, in step S63, the ideal sending time TOT is later than the cell arrival time ta, a cell sending time t0 is set to the ideal sending time TOT (step S65).
If, in step S63, the ideal sending time TOT is earlier than the cell arrival time ta, the cell sending time t0 is set to the cell arrival time ta (step S64). If, in step S66, the ideal sending time TOT is earlier than the cell arrival time considering the cell delay fluctuation (ta-.tau.1), the ideal sending time TOT is set to the time (ta-.tau.1) (step S67).
In, in step S66, the ideal sending time TOT is later than the cell arrival time considering the cell delay fluctuation (ta-.tau.1), the cell sending time t0 is kept set to the cell arrival time ta.
Next, a new ideal sending time TOT is set by adding a maximum cell sending time interval T to the ideal sending time TOT (step S68). Finally, after queuing, the cell is sent at the cell sending time t0 (step S69). The flow returns to step S62, and this process is repeated for all arriving cells.
The above-described conventional sending time determination circuit 11 determines the ideal cell sending time, and thereafter, the sendability determination unit 122 checks whether a sending reservation for another cell is present for the time. If there is no reservation, a cell sending reservation can be set for that time. However, if a reservation has already been made, a reservation for a cell sending time after the ideal cell sending time is checked. If a reservation has already been made for that time, too, the next cell sending time is checked. In this manner, the time required to determine the cell sending time becomes long.
Unless a time without any reservation is found, the cell sending time cannot be determined within one cell time which is necessary for sending one cell.
Japanese Patent Laid-Open No. 5-252185 discloses a technique for ensuring a free area of a cell storage memory and cannot solve the above problem.